<?php

class Other_request extends CI_Controller {

    function __Construct() {
        parent::__Construct();
        $this->load->database();
        $this->load->model('other_m');
        $this->load->library('form_validation');
        $this->load->library("pagination");
        $this->load->helper('url', 'form');
    }

    function index() {
        redirect('other_request/other_requested');
    }

    function other_requested() {
        $data['title'] = "Other requested!";
        $data['all_other'] = $this->other_m->all_other();

        $this->load->view('admin/other_requested', $data);
    }

    function delete() {
        $this->load->model('other_m');
        $id = $this->uri->segment(4);
        if ((int) $id > 0) {
            $oldrow = array('ID' => $id);
            $this->other_m->delete_other($oldrow);

            redirect('other_request/index');
        }
    }

}

?>